package methodref;

import java.util.function.Supplier;

public class Car {

    public static Car create(final Supplier<Car> supplier) {
        return supplier.get();
    }

    public static void collide(final Car car) {
        System.out.println("colliede" + car.toString());
    }

    public void follow(final Car another) {
        System.out.println("following the" + another.toString());
    }

    public void repair() {
        System.out.println("repaired" + this.toString());
    }

}
